sets.id=[1 2 3];
sets.name={'train'  'val'  'test'};

classes.name={'cell_image','mask'};

paths.image='../data/image/%s.jpg';
paths.classSegmentation='../data/mask/%s.png';

N=3589;Nv=289;
images.id=1:N;

files=dir('data/image'); 
for i=3:N+2
    tmp=files(i).name;
    images.name(i-2)={tmp(1:end-4)};
end

images.segmentation=ones(1,N);

images.set=ones(1,N);
rall=randperm(N);rid=rall(1:Nv);
images.set(rid)=2;

% save('imdby.mat','imdb');
save('imdb.mat','sets','classes','paths','images');